/**
 * <copyright>
 * </copyright>
 *
 * $Id$
 */
package org.admanager.soadmanagement.plugin.soadmanagement.impl;

import org.admanager.soadmanagement.plugin.soadmanagement.*;

import org.eclipse.emf.ecore.EClass;
import org.eclipse.emf.ecore.EObject;
import org.eclipse.emf.ecore.EPackage;

import org.eclipse.emf.ecore.impl.EFactoryImpl;

import org.eclipse.emf.ecore.plugin.EcorePlugin;

/**
 * <!-- begin-user-doc -->
 * An implementation of the model <b>Factory</b>.
 * <!-- end-user-doc -->
 * @generated
 */
public class soadmanagementFactoryImpl extends EFactoryImpl implements soadmanagementFactory {
	/**
	 * Creates the default factory implementation.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public static soadmanagementFactory init() {
		try {
			soadmanagementFactory thesoadmanagementFactory = (soadmanagementFactory)EPackage.Registry.INSTANCE.getEFactory("http://soageneralpattern/1.0"); 
			if (thesoadmanagementFactory != null) {
				return thesoadmanagementFactory;
			}
		}
		catch (Exception exception) {
			EcorePlugin.INSTANCE.log(exception);
		}
		return new soadmanagementFactoryImpl();
	}

	/**
	 * Creates an instance of the factory.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public soadmanagementFactoryImpl() {
		super();
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public EObject create(EClass eClass) {
		switch (eClass.getClassifierID()) {
			case soadmanagementPackage.PCOMPONENT: return createPComponent();
			case soadmanagementPackage.PCOMPOSITE: return createPComposite();
			case soadmanagementPackage.PREFERENCE: return createPReference();
			case soadmanagementPackage.PSERVICE: return createPService();
			case soadmanagementPackage.PCOMPONENT_SERVICE: return createPComponentService();
			case soadmanagementPackage.PCOMPONENT_REFERENCE: return createPComponentReference();
			case soadmanagementPackage.PELEMENT: return createPElement();
			case soadmanagementPackage.PATTERN: return createPattern();
			case soadmanagementPackage.PROLE: return createPRole();
			case soadmanagementPackage.PMULTIPLICITY: return createPMultiplicity();
			case soadmanagementPackage.PCONSTRAINT: return createPConstraint();
			case soadmanagementPackage.COMPONENT: return createComponent();
			case soadmanagementPackage.COMPOSITE: return createComposite();
			case soadmanagementPackage.REFERENCE: return createReference();
			case soadmanagementPackage.SERVICE: return createService();
			case soadmanagementPackage.COMPONENT_SERVICE: return createComponentService();
			case soadmanagementPackage.COMPONENT_REFERENCE: return createComponentReference();
			case soadmanagementPackage.DOCUMENT_ROOT: return createDocumentRoot();
			case soadmanagementPackage.ROOT_MAPPING: return createRootMapping();
			case soadmanagementPackage.COMPOSITE_MAPPING: return createCompositeMapping();
			case soadmanagementPackage.COMPONENT_MAPPING: return createComponentMapping();
			case soadmanagementPackage.REFERENCE_MAPPING: return createReferenceMapping();
			case soadmanagementPackage.SERVICE_MAPPING: return createServiceMapping();
			case soadmanagementPackage.COMPONENT_REFERENCE_MAPPING: return createComponentReferenceMapping();
			case soadmanagementPackage.COMPONENT_SERVICE_MAPPING: return createComponentServiceMapping();
			default:
				throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier");
		}
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public PComponent createPComponent() {
		PComponentImpl pComponent = new PComponentImpl();
		return pComponent;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public PComposite createPComposite() {
		PCompositeImpl pComposite = new PCompositeImpl();
		return pComposite;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public PReference createPReference() {
		PReferenceImpl pReference = new PReferenceImpl();
		return pReference;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public PService createPService() {
		PServiceImpl pService = new PServiceImpl();
		return pService;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public PComponentService createPComponentService() {
		PComponentServiceImpl pComponentService = new PComponentServiceImpl();
		return pComponentService;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public PComponentReference createPComponentReference() {
		PComponentReferenceImpl pComponentReference = new PComponentReferenceImpl();
		return pComponentReference;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public PElement createPElement() {
		PElementImpl pElement = new PElementImpl();
		return pElement;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public Pattern createPattern() {
		PatternImpl pattern = new PatternImpl();
		return pattern;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public PRole createPRole() {
		PRoleImpl pRole = new PRoleImpl();
		return pRole;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public PMultiplicity createPMultiplicity() {
		PMultiplicityImpl pMultiplicity = new PMultiplicityImpl();
		return pMultiplicity;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public PConstraint createPConstraint() {
		PConstraintImpl pConstraint = new PConstraintImpl();
		return pConstraint;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public Component createComponent() {
		ComponentImpl component = new ComponentImpl();
		return component;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public Composite createComposite() {
		CompositeImpl composite = new CompositeImpl();
		return composite;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public Reference createReference() {
		ReferenceImpl reference = new ReferenceImpl();
		return reference;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public Service createService() {
		ServiceImpl service = new ServiceImpl();
		return service;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public ComponentService createComponentService() {
		ComponentServiceImpl componentService = new ComponentServiceImpl();
		return componentService;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public ComponentReference createComponentReference() {
		ComponentReferenceImpl componentReference = new ComponentReferenceImpl();
		return componentReference;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public DocumentRoot createDocumentRoot() {
		DocumentRootImpl documentRoot = new DocumentRootImpl();
		return documentRoot;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public RootMapping createRootMapping() {
		RootMappingImpl rootMapping = new RootMappingImpl();
		return rootMapping;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public CompositeMapping createCompositeMapping() {
		CompositeMappingImpl compositeMapping = new CompositeMappingImpl();
		return compositeMapping;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public ComponentMapping createComponentMapping() {
		ComponentMappingImpl componentMapping = new ComponentMappingImpl();
		return componentMapping;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public ReferenceMapping createReferenceMapping() {
		ReferenceMappingImpl referenceMapping = new ReferenceMappingImpl();
		return referenceMapping;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public ServiceMapping createServiceMapping() {
		ServiceMappingImpl serviceMapping = new ServiceMappingImpl();
		return serviceMapping;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public ComponentReferenceMapping createComponentReferenceMapping() {
		ComponentReferenceMappingImpl componentReferenceMapping = new ComponentReferenceMappingImpl();
		return componentReferenceMapping;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public ComponentServiceMapping createComponentServiceMapping() {
		ComponentServiceMappingImpl componentServiceMapping = new ComponentServiceMappingImpl();
		return componentServiceMapping;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public soadmanagementPackage getsoadmanagementPackage() {
		return (soadmanagementPackage)getEPackage();
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @deprecated
	 * @generated
	 */
	public static soadmanagementPackage getPackage() {
		return soadmanagementPackage.eINSTANCE;
	}

} //soadmanagementFactoryImpl
